export default [
  // 发布类目展开选择页
  {
    path: '/service/release/:type',
    component: resolve => require(['views/service/Release'], resolve)
  },
  // test router
  {
    path: '/service/train',
    component: resolve => require(['views/service/Train'], resolve)
  },
  /**
   * @param{releaseType} 发布类型 product => 实体商品  activity => 活动
   * @param{editType} 编辑类型 draft => 草稿 edit => 编辑 republish => 重新发布
   * @param{goodsCode} 商品code
   * @param{goodsCateCode} 商品分类code
   */
  {
    // path: '/service/release/:releaseType/:editType/:goodsCode/:goodsCateCode', // 活动编辑 详情
    path: '/service/release/:type/edit', // 活动编辑 详情
    name: 'goodsEdit',
    component: resolve => require(['views/service/ReleaseInfo'], resolve)
  },
  {
    path: '/service/list',
    redirect: '/service/list/underway',
    component: resolve => require(['views/service/List'], resolve),
    children: [
      {
        path: '/service/list/:type',
        component: resolve => require(['views/service/components/ListItem'], resolve)
      }
    ]
  },
  {
    path: '/service/detail/:serviceId',
    name: 'detail',
    component: resolve => require(['views/service/Detail'], resolve)
  },
  {
    path: '/service/transit',
    component: resolve => require(['views/service/Transit'], resolve)
  }
]
